<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<title>主界面_普通用户</title>
<link rel="stylesheet" type="text/css" href="../../css/reset.css" />
<link rel="stylesheet" type="text/css" href="../../css/css.css" />
<link rel="stylesheet" type="text/css"
	href="../../js/jquery-easyui-1.4.3/themes/default/easyui.css" />
<link rel="stylesheet" type="text/css"
	href="../../js/jquery-easyui-1.4.3/themes/icon.css" />
<link rel="stylesheet" type="text/css"
	href="../../js/SimpleTree1.3/js/tree_themes/SimpleTree.css" />
<link rel="stylesheet" type="text/css" href="../../css/colorReset.css" />
<style>
/*body{
	width:100%;
	height:100%;
	background:url(../../images/main_bg_t.png) left top no-repeat;
}
.main{
	min-width:615px;
	min-height:370px;
	background:url(../../images/main_bg_r.png) right top no-repeat;
}*/
.main_normal>img {
	display: none;
}

.hover {
	background-color: #ffa;
}

.title {
	width: 80%;
	margin: 0 auto;
	padding: 15px 0 10px 0;
	font-size: 25px;
	text-align: center;
}

.title h2 img {
	width: 150px;
}

.title .line {
	width: 300px;
	height: 1px;
	line-height: 0px;
	border-bottom: 1px dashed #D1D1D1;
	margin: 10px auto 15px auto;
}

.title p {
	font-size: 15px;
}
/*.content dl{
	width:600px;
	margin:0 auto 20px auto;
	overflow:hidden;
	border-radius:10px;
	padding:0 0 10px 0;
	background-color:#FFFFFF;
	font-family:"黑体";
	border:4px solid #ecf0f5;
	box-shadow:2px 2px 6px #9E9E9E;
}
.content dt{
	background-color:rgb(210, 224, 242);
	font-size:28px;	
	font-weight:bold;
	line-height:100px;
	margin:0 0 10px 0;
	padding:0 0 0 10px;
	height:100px;
	background-color:#00a7d0;
	color:#FFFFFF;
	overflow:hidden;
}
.content dt img{
	padding:15px 40px 0 20px;
	-webkit-animation:upslide 1s ease-in infinite;
}*/
.content dl {
	display: none;
}

.content dl dd {
	display: block;
	margin: 0 5px;
}
/*.content dl dd a{
	display:block;	
	height:30px;
	line-height:30px;
	padding:5px 10px;
	font-size:18px;
	color:#9b9b9b;
	border-bottom:1px solid #f4f4f4;
	overflow:hidden;
}
.content dl dd a span{
	vertical-align:text-bottom;
	width:30px;
	height:30px;
	line-height:30px;
	text-align:center;
	font-size:14px;
	font-weight:bold;
	display:block;
	color:#FFFFFF;
	background-color:#dd4b39;
	border-radius:50%;
	-webkit-animation:scale 0.3s ease-in infinite;
	-webkit-animation-iteration-count:1;
}*/
@
-webkit-keyframes upslide { 0% {
	-webkit-transform: translateY(0%);
	opacity: 1;
}

50%
{
-webkit-transform
:translateY
(3%);

	
opacity
:
0
.5
;

  
}
100%
{
-webkit-transform
:translateY
(0%);

	
opacity
:
1;

  
}
}
@
-webkit-keyframes scale { 0% {
	-webkit-transform: scale(0);
	opacity: 0;
}

100%
{
-webkit-transform
:scale(1)
;

	
opacity
:
1;

  
}
}
/*.content dl dd a:hover{
	background-color:#f1f3ff;
}*/
.fl.add {
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	width: 410px;
}
</style>
</head>

<body id="main">
	<div class="main">
		<div class="title">
			<h2>
				<img src="../../images/logo.png" alt="" />
			</h2>
			<!--<div class="line"></div>
    <p>管理监控平台&nbsp;<span>Administrator  Console</span></p>-->
		</div>
		<div class="content">
			<div class="main_normal">
				<img src="../../images/main_normal_bg.png" alt="" />
				<p>正在检测中，请稍候...</p>
			</div>
			<dl>
				<dt>
					<div class="main_title">
						<img src="../../images/main_tips2.png" alt="" class="fl" />
						<p class="fl">执行出错的接口</p>
					</div>
				</dt>
				<dd>
					<a href=""><p class="fl">加载中...</p>
						<span class="fr">加载中...</span></a>
				</dd>
			</dl>
		</div>
	</div>
	<script type="text/javascript" src="/webjars/json3/3.3.2/json3.min.js"></script>
	<script type="text/javascript"
		src="../../js/jquery-easyui-1.4.3/jquery.min.js"></script>
	<script type="text/javascript"
		src="../../js/jquery-easyui-1.4.3/jquery.easyui.min.js"></script>
	<script type="text/javascript" src="../../js/cook/constants.js"></script>
	<script type="text/javascript" src="../../js/cook/public.js"></script>

	<script>
$(document).ready(function(){
	setTimeout(function(){$("#main").css("height",$(document).height())},300);
	$.ajax({
		url:BASE_URL_MAIN_PAGE_SEARCH + '/getConsumerInfo' + '?v=' + Math.random(),
		dataType:'json',
		type:'get',
		contentType:"application/json",
		success:function(data){
			if(data.backValue)
			{
				$(".main_normal > img").show();
				$(".main_normal p").html("系统运行正常！");
			}
			else
			{
				$(".main_normal").hide();
				$("dl dd").remove();
				var len = data.content.length;
				var data = data.content;
				var html = "";
				if(len > 8){ len = 8};
				for(var i = 0; i < len;i++)
				{
					if(data[i].interfaceType == "KETTLE"){
						var param = "fieldName=" + encodeURI(data[i].fieldName) + "&fieldSystemName=" + encodeURI(data[i].fieldSystemName) + "&fieldSystemId=" + data[i].fieldSystemId + "&interfaceName=" + encodeURI(data[i].interfaceName) + "&beginOfRunEndTime=" + data[i].beginOfRunEndTime + "&endOfRunEndTime=" + data[i].endOfRunEndTime;
						html += '<dd ><a href="javascript:void(0);" data-title="失败告警信息上报" data-url="pages/InterfaceMonitoring/OperationMonitoring/FailureWarningInformation.html?' + param + '"><p class="fl add"  title="'+ data[i].interfaceType + ' > ' + data[i].fieldName + ' > ' + data[i].fieldSystemName + ' > ' + data[i].interfaceName+'">' + data[i].interfaceType + ' > ' + data[i].fieldName + ' > ' + data[i].fieldSystemName + ' > ' + data[i].interfaceName + '</p><span class="fr">' + data[i].faildInterfaceCount + '</span></a></dd>';			
					}else if(data[i].interfaceType == "FTP"){
						var param = "fieldName=" + encodeURI(data[i].fieldName) + "&fieldSystemName=" + encodeURI(data[i].fieldSystemName) + "&fieldSystemId=" + data[i].fieldSystemId + "&interfaceName=" + encodeURI(data[i].interfaceName) + "&beginOfRunEndTime=" + data[i].beginOfRunEndTime + "&endOfRunEndTime=" + data[i].endOfRunEndTime;
						html += '<dd><a href="javascript:void(0);" data-title="服务日志查询" data-url="pages/esb/ServiceLogManagement/ServiceLogSearch.html?' + param + '"><p class="fl add" title="'+data[i].interfaceType + ' > ' + data[i].fieldName + ' > ' + data[i].fieldSystemName + ' > ' + data[i].interfaceName +'">' + data[i].interfaceType + ' > ' + data[i].fieldName + ' > ' + data[i].fieldSystemName + ' > ' + data[i].interfaceName + '</p><span class="fr">' + data[i].faildInterfaceCount + '</span></a></dd>';	
					}else{
						var param = "fieldName=" + encodeURI(data[i].fieldName) + "&fieldSystemName=" + encodeURI(data[i].fieldSystemName) + "&fieldSystemId=" + data[i].fieldSystemId + "&interfaceName=" + encodeURI(data[i].interfaceName) + "&beginOfRunEndTime=" + data[i].beginOfRunEndTime + "&endOfRunEndTime=" + data[i].endOfRunEndTime;
						html += '<dd><a href="javascript:void(0);" data-title="服务告警管理" data-url="pages/esb/ServiceMonitor/ServiceAlarmManagement.html?' + param + '"><p class="fl add" title="'+ data[i].interfaceType + ' > ' + data[i].fieldName + ' > ' + data[i].fieldSystemName + ' > ' + data[i].interfaceName +'">' + data[i].interfaceType + ' > ' + data[i].fieldName + ' > ' + data[i].fieldSystemName + ' > ' + data[i].interfaceName + '</p><span class="fr">' + data[i].faildInterfaceCount + '</span></a></dd>';
					}
				}
				$("dl").remove("dd").append(html);
				$("dl").fadeIn();
			}
		}
	});
	
	$("body").delegate("dd a","click",function(e) {
		var title = $(this).data("title");
		var url=$(this).data("url") + '&v=' + Math.random();
		var icon=$(this).attr("icon");
		window.parent.OpenTab(title,url,icon, true);
    });	
}); 
</script>
</body>
</html>
